package demo1;


public class Test {
    public static void main(String[] args) {
        MyBinarySearchTree myBinarySearchTree = new MyBinarySearchTree();
        myBinarySearchTree.add(12);
        myBinarySearchTree.add(2);
        myBinarySearchTree.add(6);
        myBinarySearchTree.add(8);
        myBinarySearchTree.add(25);
        myBinarySearchTree.inOrder(myBinarySearchTree.root);
        System.out.println();
        System.out.println(myBinarySearchTree.search(6));
        System.out.println(myBinarySearchTree.search(9));
        myBinarySearchTree.remove(12);
        myBinarySearchTree.remove(23);
        myBinarySearchTree.inOrder(myBinarySearchTree.root);
    }
}
